import request from '@/utils/request'

// 查询相对方管理列表
export function listCounterpart(query) {
  return request({
    url: '/counterpart/list',
    method: 'get',
    params: query
  })
}

export function listCounterpartAll(query) {
  return request({
    url: '/counterpart/listAll',
    method: 'get',
    params: query
  })
}

// 查询相对方管理详细
export function getCounterpart(id) {
  return request({
    url: '/counterpart/' + id,
    method: 'get'
  })
}

// 新增相对方管理
export function addCounterpart(data) {
  return request({
    url: '/counterpart',
    method: 'post',
    data: data
  })
}

// 修改相对方管理
export function updateCounterpart(data) {
  return request({
    url: '/counterpart',
    method: 'put',
    data: data
  })
}

// 删除相对方管理
export function delCounterpart(id) {
  return request({
    url: '/counterpart/' + id,
    method: 'delete'
  })
}
